package xin.marcher.module.seller.converter;

import org.mapstruct.Mapper;
import xin.marcher.module.seller.domain.entity.SellerGroupDO;
import xin.marcher.module.seller.domain.request.SellerGroupRequest;
import xin.marcher.module.seller.domain.response.SellerGroupResponse;

import java.util.List;

/**
 * 卖家组对象克隆
 */
@Mapper(componentModel = "spring")
public interface SellerGroupConverter {
    /**
     * 卖家组 request -> DO
     *
     * @param request
     * @return
     */
    SellerGroupDO requestToEntity(SellerGroupRequest request);

    /**
     * 卖家组 list DO -> response
     *
     * @param records
     * @return
     */
    List<SellerGroupResponse> listEntityToResponse(List<SellerGroupDO> records);
}
